# -*- coding:utf-8 -*-
from django.test import TestCase

# Create your tests here.

from users.models import AuthUser, Person, CompanyInfo
from basic.models import ElevatorInfo
from maintenance.models import Task
import time
import json
import requests
from utils.tools import get_session, another_registry_person, another_update_person


# person_qs = Person.objects.filter_active(registry_status=20)
# print person_qs.count()
# i = 0
# for person_obj in person_qs:
#     time.sleep(0.5)
#     i += 1
#     print "第 %s 位维保人员开始备案" % str(i)
#     another_update_person(Person, person_obj.id)
#     print "第 %s 位维保人员备案结束" % str(i)
#
#
#
#
# task_qs = Task.objects.filter_active(status=40).exclude(id=547)
# print task_qs.count()
# i = 0
# for task_obj in task_qs:
#     time.sleep(0.5)
#     i += 1
#     print "第 %s 位维保结果开始备案" % str(i)
#     try:
#         another_update_maintain_record(task_obj.id)
#
#     print "第 %s 位维保结果备案结束" % str(i)


